#!/usr/bin/make -f
# -*- makefile -*-

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

override_dh_auto_clean:
	rm -rf locale common/po/*.mo
	find $(CURDIR) -name "*\.py[co]" -delete
	# these get regenerated
	rm -f */man/C/*.1.gz
	rm -f common/Makefile qt/Makefile
	rm -f common/config-example-*.gz

override_dh_auto_configure:
	cd common && ./configure
	cd qt && ./configure

override_dh_auto_build:
	cd common && $(MAKE)
	cd qt && $(MAKE)

override_dh_auto_install:
	cd common && DESTDIR=../debian/backintime-common $(MAKE) install

	cd qt && DESTDIR=../debian/backintime-qt $(MAKE) install

override_dh_python3:
	dh_python3 /usr/share/backintime/

%:
	dh $@ --with python3
